<div nz-row class="main">
  <div nz-col nzSpan="10"></div>
  <div nz-col nzSpan="4">
    <h3 nz-title style="margin-top: 250px;text-align: center;color: #fff;">RBAC权限管理系统</h3>
    <input nz-input placeholder="用户名" [(ngModel)]="username" style="margin-bottom: 20px;"  (keyup)="($event.which === 13)?login():0;"/>
    <nz-input-group [nzSuffix]="suffixTemplate" style="margin-bottom: 20px;">
      <input
        [type]="passwordVisible ? 'text' : 'password'"
        nz-input
        placeholder="密码"
        [(ngModel)]="password"
        (keyup)="($event.which === 13)?login():0;"
      />
    </nz-input-group>
    <div nz-row [nzGutter]="16" style="margin-bottom: 20px;">
      <div nz-col  [nzSpan]="13">
        <input  nz-input placeholder="验证码" [(ngModel)]="code" (keyup)="($event.which === 13)?login():0;"/>
      </div>
      <div nz-col  [nzSpan]="11">
        <img [src]="img" title="看不清？点击刷新" (click)="getVerify()"/>
      </div>
    </div>
    <ng-template #suffixTemplate>
      <i nz-icon [nzType]="passwordVisible ? 'eye-invisible' : 'eye'" (click)="passwordVisible = !passwordVisible"></i>
    </ng-template>
    <button nz-button nzType="primary" nzBlock (click)="login()">登录</button>
  </div>
  <div nz-col nzSpan="10"></div>
</div>
